0 Prolog
↳1 PrologToPiTRSProof (⇒, 0 ms)
↳2 PiTRS
↳3 DependencyPairsProof (⇔, 2 ms)
↳4 PiDP
↳5 DependencyGraphProof (⇔, 17 ms)
↳6 AND
↳7 PiDP
↳8 UsableRulesProof (⇔, 0 ms)
↳9 PiDP
↳10 PiDPToQDPProof (⇒, 0 ms)
↳11 QDP
↳12 QDPSizeChangeProof (⇔, 0 ms)
↳13 YES
↳14 PiDP
↳15 UsableRulesProof (⇔, 0 ms)
↳16 PiDP
↳17 PiDPToQDPProof (⇒, 0 ms)
↳18 QDP
↳19 QDPSizeChangeProof (⇔, 0 ms)
↳20 YES
↳21 PiDP
↳22 UsableRulesProof (⇔, 0 ms)
↳23 PiDP
↳24 PiDPToQDPProof (⇒, 6 ms)
↳25 QDP
↳26 UsableRulesReductionPairsProof (⇔, 219 ms)
↳27 QDP
↳28 PisEmptyProof (⇔, 0 ms)
↳29 YES
sameleaves_in_gg(leaf(L), leaf(L)) → sameleaves_out_gg(leaf(L), leaf(L))
sameleaves_in_gg(tree(T1, T2), tree(S1, S2)) → U1_gg(T1, T2, S1, S2, getleave_in_ggaa(T1, T2, L, T))
getleave_in_ggaa(leaf(A), C, A, C) → getleave_out_ggaa(leaf(A), C, A, C)
getleave_in_ggaa(tree(A, B), C, L, O) → U4_ggaa(A, B, C, L, O, getleave_in_ggaa(A, tree(B, C), L, O))
U4_ggaa(A, B, C, L, O, getleave_out_ggaa(A, tree(B, C), L, O)) → getleave_out_ggaa(tree(A, B), C, L, O)
U1_gg(T1, T2, S1, S2, getleave_out_ggaa(T1, T2, L, T)) → U2_gg(T1, T2, S1, S2, T, getleave_in_ggga(S1, S2, L, S))
getleave_in_ggga(leaf(A), C, A, C) → getleave_out_ggga(leaf(A), C, A, C)
getleave_in_ggga(tree(A, B), C, L, O) → U4_ggga(A, B, C, L, O, getleave_in_ggga(A, tree(B, C), L, O))
U4_ggga(A, B, C, L, O, getleave_out_ggga(A, tree(B, C), L, O)) → getleave_out_ggga(tree(A, B), C, L, O)
U2_gg(T1, T2, S1, S2, T, getleave_out_ggga(S1, S2, L, S)) → U3_gg(T1, T2, S1, S2, sameleaves_in_gg(T, S))
U3_gg(T1, T2, S1, S2, sameleaves_out_gg(T, S)) → sameleaves_out_gg(tree(T1, T2), tree(S1, S2))
Infinitary Constructor Rewriting Termination of PiTRS implies Termination of Prolog
sameleaves_in_gg(leaf(L), leaf(L)) → sameleaves_out_gg(leaf(L), leaf(L))
sameleaves_in_gg(tree(T1, T2), tree(S1, S2)) → U1_gg(T1, T2, S1, S2, getleave_in_ggaa(T1, T2, L, T))
getleave_in_ggaa(leaf(A), C, A, C) → getleave_out_ggaa(leaf(A), C, A, C)
getleave_in_ggaa(tree(A, B), C, L, O) → U4_ggaa(A, B, C, L, O, getleave_in_ggaa(A, tree(B, C), L, O))
U4_ggaa(A, B, C, L, O, getleave_out_ggaa(A, tree(B, C), L, O)) → getleave_out_ggaa(tree(A, B), C, L, O)
U1_gg(T1, T2, S1, S2, getleave_out_ggaa(T1, T2, L, T)) → U2_gg(T1, T2, S1, S2, T, getleave_in_ggga(S1, S2, L, S))
getleave_in_ggga(leaf(A), C, A, C) → getleave_out_ggga(leaf(A), C, A, C)
getleave_in_ggga(tree(A, B), C, L, O) → U4_ggga(A, B, C, L, O, getleave_in_ggga(A, tree(B, C), L, O))
U4_ggga(A, B, C, L, O, getleave_out_ggga(A, tree(B, C), L, O)) → getleave_out_ggga(tree(A, B), C, L, O)
U2_gg(T1, T2, S1, S2, T, getleave_out_ggga(S1, S2, L, S)) → U3_gg(T1, T2, S1, S2, sameleaves_in_gg(T, S))
U3_gg(T1, T2, S1, S2, sameleaves_out_gg(T, S)) → sameleaves_out_gg(tree(T1, T2), tree(S1, S2))
SAMELEAVES_IN_GG(tree(T1, T2), tree(S1, S2)) → U1_GG(T1, T2, S1, S2, getleave_in_ggaa(T1, T2, L, T))
SAMELEAVES_IN_GG(tree(T1, T2), tree(S1, S2)) → GETLEAVE_IN_GGAA(T1, T2, L, T)
GETLEAVE_IN_GGAA(tree(A, B), C, L, O) → U4_GGAA(A, B, C, L, O, getleave_in_ggaa(A, tree(B, C), L, O))
GETLEAVE_IN_GGAA(tree(A, B), C, L, O) → GETLEAVE_IN_GGAA(A, tree(B, C), L, O)
U1_GG(T1, T2, S1, S2, getleave_out_ggaa(T1, T2, L, T)) → U2_GG(T1, T2, S1, S2, T, getleave_in_ggga(S1, S2, L, S))
U1_GG(T1, T2, S1, S2, getleave_out_ggaa(T1, T2, L, T)) → GETLEAVE_IN_GGGA(S1, S2, L, S)
GETLEAVE_IN_GGGA(tree(A, B), C, L, O) → U4_GGGA(A, B, C, L, O, getleave_in_ggga(A, tree(B, C), L, O))
GETLEAVE_IN_GGGA(tree(A, B), C, L, O) → GETLEAVE_IN_GGGA(A, tree(B, C), L, O)
U2_GG(T1, T2, S1, S2, T, getleave_out_ggga(S1, S2, L, S)) → U3_GG(T1, T2, S1, S2, sameleaves_in_gg(T, S))
U2_GG(T1, T2, S1, S2, T, getleave_out_ggga(S1, S2, L, S)) → SAMELEAVES_IN_GG(T, S)
sameleaves_in_gg(leaf(L), leaf(L)) → sameleaves_out_gg(leaf(L), leaf(L))
sameleaves_in_gg(tree(T1, T2), tree(S1, S2)) → U1_gg(T1, T2, S1, S2, getleave_in_ggaa(T1, T2, L, T))
getleave_in_ggaa(leaf(A), C, A, C) → getleave_out_ggaa(leaf(A), C, A, C)
getleave_in_ggaa(tree(A, B), C, L, O) → U4_ggaa(A, B, C, L, O, getleave_in_ggaa(A, tree(B, C), L, O))
U4_ggaa(A, B, C, L, O, getleave_out_ggaa(A, tree(B, C), L, O)) → getleave_out_ggaa(tree(A, B), C, L, O)
U1_gg(T1, T2, S1, S2, getleave_out_ggaa(T1, T2, L, T)) → U2_gg(T1, T2, S1, S2, T, getleave_in_ggga(S1, S2, L, S))
getleave_in_ggga(leaf(A), C, A, C) → getleave_out_ggga(leaf(A), C, A, C)
getleave_in_ggga(tree(A, B), C, L, O) → U4_ggga(A, B, C, L, O, getleave_in_ggga(A, tree(B, C), L, O))
U4_ggga(A, B, C, L, O, getleave_out_ggga(A, tree(B, C), L, O)) → getleave_out_ggga(tree(A, B), C, L, O)
U2_gg(T1, T2, S1, S2, T, getleave_out_ggga(S1, S2, L, S)) → U3_gg(T1, T2, S1, S2, sameleaves_in_gg(T, S))
U3_gg(T1, T2, S1, S2, sameleaves_out_gg(T, S)) → sameleaves_out_gg(tree(T1, T2), tree(S1, S2))
SAMELEAVES_IN_GG(tree(T1, T2), tree(S1, S2)) → U1_GG(T1, T2, S1, S2, getleave_in_ggaa(T1, T2, L, T))
SAMELEAVES_IN_GG(tree(T1, T2), tree(S1, S2)) → GETLEAVE_IN_GGAA(T1, T2, L, T)
GETLEAVE_IN_GGAA(tree(A, B), C, L, O) → U4_GGAA(A, B, C, L, O, getleave_in_ggaa(A, tree(B, C), L, O))
GETLEAVE_IN_GGAA(tree(A, B), C, L, O) → GETLEAVE_IN_GGAA(A, tree(B, C), L, O)
U1_GG(T1, T2, S1, S2, getleave_out_ggaa(T1, T2, L, T)) → U2_GG(T1, T2, S1, S2, T, getleave_in_ggga(S1, S2, L, S))
U1_GG(T1, T2, S1, S2, getleave_out_ggaa(T1, T2, L, T)) → GETLEAVE_IN_GGGA(S1, S2, L, S)
GETLEAVE_IN_GGGA(tree(A, B), C, L, O) → U4_GGGA(A, B, C, L, O, getleave_in_ggga(A, tree(B, C), L, O))
GETLEAVE_IN_GGGA(tree(A, B), C, L, O) → GETLEAVE_IN_GGGA(A, tree(B, C), L, O)
U2_GG(T1, T2, S1, S2, T, getleave_out_ggga(S1, S2, L, S)) → U3_GG(T1, T2, S1, S2, sameleaves_in_gg(T, S))
U2_GG(T1, T2, S1, S2, T, getleave_out_ggga(S1, S2, L, S)) → SAMELEAVES_IN_GG(T, S)
sameleaves_in_gg(leaf(L), leaf(L)) → sameleaves_out_gg(leaf(L), leaf(L))
sameleaves_in_gg(tree(T1, T2), tree(S1, S2)) → U1_gg(T1, T2, S1, S2, getleave_in_ggaa(T1, T2, L, T))
getleave_in_ggaa(leaf(A), C, A, C) → getleave_out_ggaa(leaf(A), C, A, C)
getleave_in_ggaa(tree(A, B), C, L, O) → U4_ggaa(A, B, C, L, O, getleave_in_ggaa(A, tree(B, C), L, O))
U4_ggaa(A, B, C, L, O, getleave_out_ggaa(A, tree(B, C), L, O)) → getleave_out_ggaa(tree(A, B), C, L, O)
U1_gg(T1, T2, S1, S2, getleave_out_ggaa(T1, T2, L, T)) → U2_gg(T1, T2, S1, S2, T, getleave_in_ggga(S1, S2, L, S))
getleave_in_ggga(leaf(A), C, A, C) → getleave_out_ggga(leaf(A), C, A, C)
getleave_in_ggga(tree(A, B), C, L, O) → U4_ggga(A, B, C, L, O, getleave_in_ggga(A, tree(B, C), L, O))
U4_ggga(A, B, C, L, O, getleave_out_ggga(A, tree(B, C), L, O)) → getleave_out_ggga(tree(A, B), C, L, O)
U2_gg(T1, T2, S1, S2, T, getleave_out_ggga(S1, S2, L, S)) → U3_gg(T1, T2, S1, S2, sameleaves_in_gg(T, S))
U3_gg(T1, T2, S1, S2, sameleaves_out_gg(T, S)) → sameleaves_out_gg(tree(T1, T2), tree(S1, S2))
GETLEAVE_IN_GGGA(tree(A, B), C, L, O) → GETLEAVE_IN_GGGA(A, tree(B, C), L, O)
sameleaves_in_gg(leaf(L), leaf(L)) → sameleaves_out_gg(leaf(L), leaf(L))
sameleaves_in_gg(tree(T1, T2), tree(S1, S2)) → U1_gg(T1, T2, S1, S2, getleave_in_ggaa(T1, T2, L, T))
getleave_in_ggaa(leaf(A), C, A, C) → getleave_out_ggaa(leaf(A), C, A, C)
getleave_in_ggaa(tree(A, B), C, L, O) → U4_ggaa(A, B, C, L, O, getleave_in_ggaa(A, tree(B, C), L, O))
U4_ggaa(A, B, C, L, O, getleave_out_ggaa(A, tree(B, C), L, O)) → getleave_out_ggaa(tree(A, B), C, L, O)
U1_gg(T1, T2, S1, S2, getleave_out_ggaa(T1, T2, L, T)) → U2_gg(T1, T2, S1, S2, T, getleave_in_ggga(S1, S2, L, S))
getleave_in_ggga(leaf(A), C, A, C) → getleave_out_ggga(leaf(A), C, A, C)
getleave_in_ggga(tree(A, B), C, L, O) → U4_ggga(A, B, C, L, O, getleave_in_ggga(A, tree(B, C), L, O))
U4_ggga(A, B, C, L, O, getleave_out_ggga(A, tree(B, C), L, O)) → getleave_out_ggga(tree(A, B), C, L, O)
U2_gg(T1, T2, S1, S2, T, getleave_out_ggga(S1, S2, L, S)) → U3_gg(T1, T2, S1, S2, sameleaves_in_gg(T, S))
U3_gg(T1, T2, S1, S2, sameleaves_out_gg(T, S)) → sameleaves_out_gg(tree(T1, T2), tree(S1, S2))
GETLEAVE_IN_GGGA(tree(A, B), C, L, O) → GETLEAVE_IN_GGGA(A, tree(B, C), L, O)
GETLEAVE_IN_GGGA(tree(A, B), C, L) → GETLEAVE_IN_GGGA(A, tree(B, C), L)
From the DPs we obtained the following set of size-change graphs:
GETLEAVE_IN_GGAA(tree(A, B), C, L, O) → GETLEAVE_IN_GGAA(A, tree(B, C), L, O)
sameleaves_in_gg(leaf(L), leaf(L)) → sameleaves_out_gg(leaf(L), leaf(L))
sameleaves_in_gg(tree(T1, T2), tree(S1, S2)) → U1_gg(T1, T2, S1, S2, getleave_in_ggaa(T1, T2, L, T))
getleave_in_ggaa(leaf(A), C, A, C) → getleave_out_ggaa(leaf(A), C, A, C)
getleave_in_ggaa(tree(A, B), C, L, O) → U4_ggaa(A, B, C, L, O, getleave_in_ggaa(A, tree(B, C), L, O))
U4_ggaa(A, B, C, L, O, getleave_out_ggaa(A, tree(B, C), L, O)) → getleave_out_ggaa(tree(A, B), C, L, O)
U1_gg(T1, T2, S1, S2, getleave_out_ggaa(T1, T2, L, T)) → U2_gg(T1, T2, S1, S2, T, getleave_in_ggga(S1, S2, L, S))
getleave_in_ggga(leaf(A), C, A, C) → getleave_out_ggga(leaf(A), C, A, C)
getleave_in_ggga(tree(A, B), C, L, O) → U4_ggga(A, B, C, L, O, getleave_in_ggga(A, tree(B, C), L, O))
U4_ggga(A, B, C, L, O, getleave_out_ggga(A, tree(B, C), L, O)) → getleave_out_ggga(tree(A, B), C, L, O)
U2_gg(T1, T2, S1, S2, T, getleave_out_ggga(S1, S2, L, S)) → U3_gg(T1, T2, S1, S2, sameleaves_in_gg(T, S))
U3_gg(T1, T2, S1, S2, sameleaves_out_gg(T, S)) → sameleaves_out_gg(tree(T1, T2), tree(S1, S2))
GETLEAVE_IN_GGAA(tree(A, B), C, L, O) → GETLEAVE_IN_GGAA(A, tree(B, C), L, O)
GETLEAVE_IN_GGAA(tree(A, B), C) → GETLEAVE_IN_GGAA(A, tree(B, C))
From the DPs we obtained the following set of size-change graphs:
U1_GG(T1, T2, S1, S2, getleave_out_ggaa(T1, T2, L, T)) → U2_GG(T1, T2, S1, S2, T, getleave_in_ggga(S1, S2, L, S))
U2_GG(T1, T2, S1, S2, T, getleave_out_ggga(S1, S2, L, S)) → SAMELEAVES_IN_GG(T, S)
SAMELEAVES_IN_GG(tree(T1, T2), tree(S1, S2)) → U1_GG(T1, T2, S1, S2, getleave_in_ggaa(T1, T2, L, T))
sameleaves_in_gg(leaf(L), leaf(L)) → sameleaves_out_gg(leaf(L), leaf(L))
sameleaves_in_gg(tree(T1, T2), tree(S1, S2)) → U1_gg(T1, T2, S1, S2, getleave_in_ggaa(T1, T2, L, T))
getleave_in_ggaa(leaf(A), C, A, C) → getleave_out_ggaa(leaf(A), C, A, C)
getleave_in_ggaa(tree(A, B), C, L, O) → U4_ggaa(A, B, C, L, O, getleave_in_ggaa(A, tree(B, C), L, O))
U4_ggaa(A, B, C, L, O, getleave_out_ggaa(A, tree(B, C), L, O)) → getleave_out_ggaa(tree(A, B), C, L, O)
U1_gg(T1, T2, S1, S2, getleave_out_ggaa(T1, T2, L, T)) → U2_gg(T1, T2, S1, S2, T, getleave_in_ggga(S1, S2, L, S))
getleave_in_ggga(leaf(A), C, A, C) → getleave_out_ggga(leaf(A), C, A, C)
getleave_in_ggga(tree(A, B), C, L, O) → U4_ggga(A, B, C, L, O, getleave_in_ggga(A, tree(B, C), L, O))
U4_ggga(A, B, C, L, O, getleave_out_ggga(A, tree(B, C), L, O)) → getleave_out_ggga(tree(A, B), C, L, O)
U2_gg(T1, T2, S1, S2, T, getleave_out_ggga(S1, S2, L, S)) → U3_gg(T1, T2, S1, S2, sameleaves_in_gg(T, S))
U3_gg(T1, T2, S1, S2, sameleaves_out_gg(T, S)) → sameleaves_out_gg(tree(T1, T2), tree(S1, S2))
U1_GG(T1, T2, S1, S2, getleave_out_ggaa(T1, T2, L, T)) → U2_GG(T1, T2, S1, S2, T, getleave_in_ggga(S1, S2, L, S))
U2_GG(T1, T2, S1, S2, T, getleave_out_ggga(S1, S2, L, S)) → SAMELEAVES_IN_GG(T, S)
SAMELEAVES_IN_GG(tree(T1, T2), tree(S1, S2)) → U1_GG(T1, T2, S1, S2, getleave_in_ggaa(T1, T2, L, T))
getleave_in_ggga(leaf(A), C, A, C) → getleave_out_ggga(leaf(A), C, A, C)
getleave_in_ggga(tree(A, B), C, L, O) → U4_ggga(A, B, C, L, O, getleave_in_ggga(A, tree(B, C), L, O))
getleave_in_ggaa(leaf(A), C, A, C) → getleave_out_ggaa(leaf(A), C, A, C)
getleave_in_ggaa(tree(A, B), C, L, O) → U4_ggaa(A, B, C, L, O, getleave_in_ggaa(A, tree(B, C), L, O))
U4_ggga(A, B, C, L, O, getleave_out_ggga(A, tree(B, C), L, O)) → getleave_out_ggga(tree(A, B), C, L, O)
U4_ggaa(A, B, C, L, O, getleave_out_ggaa(A, tree(B, C), L, O)) → getleave_out_ggaa(tree(A, B), C, L, O)
U1_GG(S1, S2, getleave_out_ggaa(L, T)) → U2_GG(T, getleave_in_ggga(S1, S2, L))
U2_GG(T, getleave_out_ggga(S)) → SAMELEAVES_IN_GG(T, S)
SAMELEAVES_IN_GG(tree(T1, T2), tree(S1, S2)) → U1_GG(S1, S2, getleave_in_ggaa(T1, T2))
getleave_in_ggga(leaf(A), C, A) → getleave_out_ggga(C)
getleave_in_ggga(tree(A, B), C, L) → U4_ggga(getleave_in_ggga(A, tree(B, C), L))
getleave_in_ggaa(leaf(A), C) → getleave_out_ggaa(A, C)
getleave_in_ggaa(tree(A, B), C) → U4_ggaa(getleave_in_ggaa(A, tree(B, C)))
U4_ggga(getleave_out_ggga(O)) → getleave_out_ggga(O)
U4_ggaa(getleave_out_ggaa(L, O)) → getleave_out_ggaa(L, O)
getleave_in_ggga(x0, x1, x2)
getleave_in_ggaa(x0, x1)
U4_ggga(x0)
U4_ggaa(x0)
The following rules are removed from R:
U1_GG(S1, S2, getleave_out_ggaa(L, T)) → U2_GG(T, getleave_in_ggga(S1, S2, L))
U2_GG(T, getleave_out_ggga(S)) → SAMELEAVES_IN_GG(T, S)
SAMELEAVES_IN_GG(tree(T1, T2), tree(S1, S2)) → U1_GG(S1, S2, getleave_in_ggaa(T1, T2))
Used ordering: POLO with Polynomial interpretation [POLO]:
getleave_in_ggga(leaf(A), C, A) → getleave_out_ggga(C)
getleave_in_ggga(tree(A, B), C, L) → U4_ggga(getleave_in_ggga(A, tree(B, C), L))
getleave_in_ggaa(leaf(A), C) → getleave_out_ggaa(A, C)
U4_ggga(getleave_out_ggga(O)) → getleave_out_ggga(O)
U4_ggaa(getleave_out_ggaa(L, O)) → getleave_out_ggaa(L, O)
POL(SAMELEAVES_IN_GG(x1, x2)) = x1 + x2
POL(U1_GG(x1, x2, x3)) = 2 + 2·x1 + x2 + x3
POL(U2_GG(x1, x2)) = 1 + x1 + x2
POL(U4_ggaa(x1)) = 2 + x1
POL(U4_ggga(x1)) = 1 + x1
POL(getleave_in_ggaa(x1, x2)) = 2·x1 + x2
POL(getleave_in_ggga(x1, x2, x3)) = 2·x1 + x2 + x3
POL(getleave_out_ggaa(x1, x2)) = 2 + x1 + x2
POL(getleave_out_ggga(x1)) = x1
POL(leaf(x1)) = 2 + 2·x1
POL(tree(x1, x2)) = 2 + 2·x1 + x2
getleave_in_ggaa(tree(A, B), C) → U4_ggaa(getleave_in_ggaa(A, tree(B, C)))
getleave_in_ggga(x0, x1, x2)
getleave_in_ggaa(x0, x1)
U4_ggga(x0)
U4_ggaa(x0)